package app.service.impl;

import java.util.List;

import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import app.dao.MessageDao;
import app.domain.Message;
import app.service.MessageService;

@Service
public class MessageServiceImpl implements MessageService{
    @Autowired
    private MessageDao messageDao;
	@Override
	public void addMessage(Message message) {
		messageDao.add(message);
	}

	@Override
	public List<Message> getMessage(int accountId) {
		return messageDao.getByAccountId(accountId);
	}

}
